<template>
  <wd-icon class="cusWdIcon" :class="customClass" :name="`${name}`" :bind="restAttrs"></wd-icon>
</template>
<script lang="ts" setup name="cus-wd-icon">
import { iconProps } from 'wot-design-uni/components/wd-icon/types'
type CusWdIconProps = typeof iconProps & {
  type: string
}
const app = getCurrentInstance()
const { name, type, ...restAttrs } = app.attrs as CusWdIconProps
const customClass = computed(() => {
  return `${type}`
})
</script>

<style scoped lang="scss">
.cusWdIcon {
  &.wd-icon {
    &.primary {
      color: var(--wot-color-theme);
    }
  }
}
</style>
